Missing files are a common problem on web sites and how you deal with them can make all the difference between a professional and unprofessional appearance. NetPresenz's missing file handling routines have multiple fall back layers which enable you to guarantee a customised response to the user.
How They Work
If a file is requested which is absent NetPresenz searches backwards up the directory structure for a 'Missing.shtml|html|cgi|acgi|fcgi' file. If the client looks for:/dir1/dir2/dir3/nothere.htmlNetPresenz looks for (in order):/dir1/dir2/dir3/missing.shtml /dir1/dir2/dir3/missing.html /dir1/dir2/dir3/missing.cgi /dir1/dir2/dir3/missing.acgi /dir1/dir2/dir3/missing.fcgi /dir1/dir2/missing.shtml /dir1/dir2/missing.html […etc…]Since CGIs are passed the original URL (with the full path) a clever CGI could 'fake' the existence of the missing file, or at least respond intelligently to the request for the missing file.A well designed Missing CGI can fake the existence of entire hierachies, or be used to 'mirror' portions of the site, intelligently parsing the incoming text to provide Server Side Include like functionality.
Examples
Example 1 This first example demonstrates the simplest case- a missing.html file in the current directory. Example 2 This example demonstrates a slightly more complex case, a missing.shtml and a missing.html file in the same directory. Example 3 This example has a missing.cgi, missing.shtml and missing.html file in the same directory. Example 4 No mising files are present in the directory. Instead, NetPresenz searches up a directory and locates the missing.shtml file in the directory above.